Repository navigation
Fix visual-check pixel diff for ImageMagick 7 output - #19
Merged
Merged
Conversation
There was a problem hiding this comment.
All reported issues were addressed across 1 file
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
[Medium impact] The changes since the previous review appear safe to merge. SummaryUpdates the pixel check in
Reviews (3) · Last reviewed commit: "Replace regex with glob check in visual-..." · Reviewed by Greptile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
ubuntu-latestnow runs Ubuntu 26.04 with ImageMagick 7 (imagemagick-7.q16).For identical images,
compare -metric AEprints0 (0)on ImageMagick 7 instead of0on ImageMagick 6, causing the strict[ "$PIXELS" != "0" ]check invisual-checkto fail on every showcase PNG despite zero differing pixels.Change
.github/workflows/pr.yaml: Check both thecompareexit status (0) and output matching either0(ImageMagick 6) or0 (0)(ImageMagick 7), and include the exit status and output in failure warnings.Verification
compare -metric AEoutput and exit status locally with ImageMagick 7.1.2 (0 (0)/ exit0for identical PNGs; non-zero count / exit1for differing PNGs).0,0 (0), differing pixel counts, multiline output, and non-zero exit codes on both Bash 3.2 and Bash 5..github/workflows/pr.yamlYAML syntax.Summary by cubic
Fixes the visual-check pixel diff failing on every showcase PNG when
ubuntu-latestruns ImageMagick 7, which prints0 (0)for identical images instead of0.The check now targets ImageMagick 7 output only: it treats
0 (0)with exit status 0 as identical, reports higher pixel counts as pixel diffs, and reports exit codes above 1 or unexpected output ascomparefailures.Written for commit 6ec1b1a. Summary will update on new commits.